import Vue from 'vue'
import VueRouter from 'vue-router'
import home from '../components/home/home.vue'
import Goodscomment from '../components/Goods/Goodscomment.vue'
// 图片
import list from '../components/poto/list.vue'
// 图片详情
import info from '../components/poto/info.vue'
// 搜索框
// import search from '../components/search/search.vue'
import Goods from '../components/Goods/Goods.vue'
import details from '../components/Goods/Goodsdetails.vue'
import Goodstext from '../components/Goods/Goodstext.vue'
import News from '../components/views/news.vue'
import News_details from '../components/views/news_details.vue'
import shoppingCar from '../components/Goods/shopping-Car.vue'
import Search from '../components/commonet/search.vue'
import add from '../components/commonet/add.vue'
Vue.use(VueRouter)


const router = new VueRouter({
  routes:[
    {path:'/',redirect:'/home'},
    {path:'/home',component:home},
    {path:'/goodscomment',component:Goodscomment},
    {path:'/poto/list',component:list},
    {path:'/poto/info',component:info},
    // {path:'/search',component:search},
    {path:'/goods',component:Goods},
    {path:'/details',component:details},
    {path:'/goodstext',component:Goodstext},
    {path: "/news",component: News},
    {path: "/new_detail",component: News_details},
    { path: '/car', component: shoppingCar},
    {path:'/search',component:Search},
    {path:'/add',component:add}
  ]})


export default router
